package com.zjp.pojo;

import com.fasterxml.jackson.annotation.JsonInclude;



public class User {
    @JsonInclude(JsonInclude.Include.NON_NULL)
    private Long id;

    private String name;

    private String sex;

    private String pic;

    private String password;

    private String email;

    private String tel;

    private String idcard;

    private Integer roleid;

    private Integer accountStatus;

    private String detailedAddress;

    private Integer healthStatus;

    public User(Long id, String name, String sex, String pic, String password, String email, String tel, String idcard, Integer roleid, Integer accountStatus, String detailedAddress, Integer healthStatus) {
        this.id = id;
        this.name = name;
        this.sex = sex;
        this.pic = pic;
        this.password = password;
        this.email = email;
        this.tel = tel;
        this.idcard = idcard;
        this.roleid = roleid;
        this.accountStatus = accountStatus;
        this.detailedAddress = detailedAddress;
        this.healthStatus = healthStatus;
    }

    public User() {
        super();
    }


    @JsonInclude(JsonInclude.Include.NON_NULL)
    public long getId() {
        return id  != null ? id : 0L;
    }


    public void setId(Long id) {
        this.id = id;
    }


    public String getName() {return name;}

    public void setName(String name) {
        this.name = name == null ? null : name.trim();
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex == null ? null : sex.trim();
    }

    public String getPic() {
        return pic;
    }

    public void setPic(String pic) {
        this.pic = pic == null ? null : pic.trim();
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password == null ? null : password.trim();
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email == null ? null : email.trim();
    }

    public String getTel() {
        return tel;
    }

    public void setTel(String tel) {
        this.tel = tel == null ? null : tel.trim();
    }

    public String getIdcard() {
        return idcard;
    }

    public void setIdcard(String idcard) {
        this.idcard = idcard == null ? null : idcard.trim();
    }

    public Integer getRoleid() {
        return roleid;
    }

    public void setRoleid(Integer roleid) {
        this.roleid = roleid;
    }

    public Integer getAccountStatus() {
        return accountStatus;
    }

    public void setAccountStatus(Integer accountStatus) {
        this.accountStatus = accountStatus;
    }

    public String getDetailedAddress() {
        return detailedAddress;
    }

    public void setDetailedAddress(String detailedAddress) {
        this.detailedAddress = detailedAddress == null ? null : detailedAddress.trim();
    }

    public Integer getHealthStatus() {
        return healthStatus;
    }

    public void setHealthStatus(Integer healthStatus) {
        this.healthStatus = healthStatus;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", name='" + name + '\'' +
                ", sex='" + sex + '\'' +
                ", pic='" + pic + '\'' +
                ", password='" + password + '\'' +
                ", email='" + email + '\'' +
                ", tel='" + tel + '\'' +
                ", idcard='" + idcard + '\'' +
                ", roleid=" + roleid +
                ", accountStatus=" + accountStatus +
                ", detailedAddress='" + detailedAddress + '\'' +
                ", healthStatus=" + healthStatus +
                '}';
    }
}